/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package sessionBean;

import java.rmi.RemoteException;
import java.util.Collection;
import java.util.HashMap;
import javax.ejb.EJBObject;
import javax.xml.transform.dom.DOMSource;

/**
 * Remote Interface for SessionBean
 * @author Konstantin
 * @see SessionBean
 */
public interface Session extends EJBObject {
    
    /**
     * Returns value of <i>searchByReference</i> from database
     * @return Boolean value of searchByReference
     * @throws RemoteException
     * @see RemoteException
     */
    public Boolean getSearchByReference ()
            throws RemoteException;
    /**
     * Export objects from database into XML
     * @param keys
     * @throws RemoteException
     * @see RemoteException
     */
    public DOMSource getXML(HashMap<Integer, Collection> keys)
            throws RemoteException;
    
    /**
     * Import objects from XML into database
     * @param path Address of XML file 
     * @return Collection with solvable and unsolvable conflicts
     * @throws RemoteException 
     * @see RemoteException
     */
    public Collection[] importFile(String path)
            throws RemoteException;
    
    /**
     * Sets searchByReference in database
     * @param useReference
     * @throws RemoteException 
     * @see RemoteException
     */
    public void setSearchByReference (Boolean useReference)
            throws RemoteException;
}
